<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
		  "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Taglib in JSP Example</title>
</head>
<body>

<jsp:useBean id="students" 
                    class="com.theopentutorials.servlets.StudentsBean"> 
   <jsp:setProperty name="students" property="firstName"
                    value="Zara"/>
   <jsp:setProperty name="students" property="lastName" 
                    value="Ali"/>
   <jsp:setProperty name="students" property="age" 
                    value="100"/> 
</jsp:useBean>
<p>Student First Name: 
   <jsp:getProperty name="students" property="firstName"/>
</p>
<p>Student Last Name: 
   <jsp:getProperty name="students" property="lastName"/>
</p>
<p>Student Age: 
   <jsp:getProperty name="students" property="age"/>
</p>
<div>
	<c:set var="test" value="Taglib Directive in JSP Example"></c:set>
        <c:out value="${test}"></c:out>
</div>
<a href="test.jsp?id=5">JSP Request Object Example</a><br>

<% 
		session.setAttribute("productName", "Pen");

		out.println("out.print example\n\t");

	%>
<a href="test.jsp?id=6">JSP Session Example</a>

<% 
		application.setAttribute("name", "Jwalant");
	%>
	<a href="test.jsp?id=7">JSP Application Example</a>
	
<fmt:formatNumber value="4578.87" type="NUMBER" maxFractionDigits="2"></fmt:formatNumber>
 <fmt:message key="thankYouMessage"></fmt:message>
	
</body>
</html>   